package com.accenture.training.service;
import org.springframework.jdbc.core.RowMapper;
import com.accenture.training.domain.Client;
import java.sql.ResultSet;
import java.sql.SQLException;

public class ClientMapper implements RowMapper<Client> {
	
	public Client mapRow(ResultSet rs, int rowNum) throws SQLException {
	      Client client = new Client();
	      client.setId(rs.getInt("id"));
	      client.setName(rs.getString("name"));
	      client.setAge(rs.getInt("age"));
	      return client;
	   }

}
